<template>
  <div>
    <div @click="back">
      <van-nav-bar left-text="返回" left-arrow title="看电影" />
    </div>
    <div>
      <van-swipe class="my-swipe" :autoplay="3000" indicator-color="white">
        <van-swipe-item v-for="item in adlistA" :key="item.id">
          <img :src="'http://124.93.196.45:10001/'+item.advImg" alt />
        </van-swipe-item>
      </van-swipe>
      <MovieList></MovieList>
    </div>
  </div>
</template>
<script>
import { adList } from '@/service/movie'
import mixin from '@/mixin/flag'
import MovieList from './MovieList.vue'
export default {
  mixins: [mixin],
  components: {
    MovieList,
  },

  data() {
    return {
      adlistA: [], // 广告轮播图
      value: '',
      flag: true,
    }
  },

  async created() {
    let res = await adList()
    this.adlistA = res.data.rows
  },

  mounted() {},

  methods: {
    back() {
      this.$router.push('/')
    },
    goto() {
      this.$router.push('/TicketView')
    },
    listgd() {
      this.flag = false
    },
  },
}
</script>
<style lang="scss" scoped>
.my-swipe .van-swipe-item {
  color: #fff;
  font-size: 20px;
  line-height: 150px;
  text-align: center;
  background-color: #39a9ed;
}

::-webkit-input-placeholder {
  /* WebKit browsers */
  color: #999;
  font-size: 14px;
}
.fasl{
  font-size: 14px;
  text-align: center;
  padding-top: 150px;
}
._cen{
  width: 100%;
  height: 40px;
  line-height: 40px;
  font-size: 14px;
  text-align: center;
}
</style>